package com.suray.wcs.service.execption;

import com.suray.basic.wcs.path.core.Node;

public class IllegalCellException extends RuntimeException {
    /**
     *
     */
    private static final long serialVersionUID = 1L;
    private Node grid;
    private String cellData;

    public IllegalCellException(Node grid, String cellData) {
        super("Excel中第"+(grid.getZ()+1)+"个Sheet的第"+(grid.getX()+2)+"行或第"+(grid.getY()+2)+"列格式不合法，原因:" + cellData);
        this.grid = grid;
        this.cellData = cellData;
    }

    public IllegalCellException(String msg) {
        super(msg);
        this.cellData = msg;
    }

    public void setGrid(Node grid) {
        this.grid = grid;
    }

    public String getCellData() {
        return cellData;
    }

}
